import java.util.Arrays;
import java.util.Scanner;

class TestTriangle {
    public static void main(String[] args) {
        Scanner input = new Scanner(System.in);
        double side1 = input.nextDouble();
        double side2 = input.nextDouble();
        double side3 = input.nextDouble();
        input.nextLine();
        Triangle triangle = new Triangle(side1, side2, side3);
        String color = input.nextLine();
        triangle.setColor(color);
        boolean filled = input.nextBoolean();
        triangle.setFilled(filled);
        System.out.println("The area is " + triangle.getArea());
        System.out.println("The perimeter is "
                + triangle.getPerimeter());
        System.out.println(triangle);
    }
}
public class Triangle extends GeometricObject {

    public Triangle(){}
    public Triangle(double side1, double side2, double side3) {

        if(Math.abs(side1 + side2) > side3
            && Math.abs(side3 + side2) > side1
            && Math.abs(side1 + side3) > side2) {
            this.side1 = side1;
            this.side2 = side2;
            this.side3 = side3;
        }
    }
    public double getSide1() {
        return side1;
    }

    public double getSide2() {
        return side2;
    }

    public double getSide3() {
        return side3;
    }
    public double getPerimeter(){
        return side1 + side2 + side3;
    }
    public double getArea(){
        double perimeter_half = getPerimeter()/2;
        return Math.sqrt(perimeter_half
                *(perimeter_half-side1)
                *(perimeter_half-side2)
                *(perimeter_half-side3));
    }
    private double side1 = 1.0,side2 = 1.0,side3 = 1.0;

    @Override
    public String toString() {
        return "Triangle: side1 = " + side1 + " side2 = " + side2 +
                " side3 = " + side3 +  " color = " + getColor() +
                " fiiled = " + isFilled();
    }
}
class GeometricObject {
    private String color = "white";
    private boolean filled;
    private java.util.Date dateCreated;
    /** Construct a default geometric object */
    protected GeometricObject() {
        dateCreated = new java.util.Date();
    }
    /** Construct a geometric object with color and filled value */
    protected GeometricObject(String color, boolean filled) {
        dateCreated = new java.util.Date();
        this.color = color;
        this.filled = filled;
    }
    /** Return color */
    public String getColor() {
        return color;
    }
    /** Set a new color */
    public void setColor(String color) {
        this.color = color;
    }
    /** Return filled. Since filled is boolean,
     *  the get method is named isFilled */
    public boolean isFilled() {
        return filled;
    }
    /** Set a new filled */
    public void setFilled(boolean filled) {
        this.filled = filled;
    }
    /** Get dateCreated */
    public java.util.Date getDateCreated() {
        return dateCreated;
    }
    @Override
    public String toString() {
        return "created on " + dateCreated + "\ncolor: " + color +
                " and filled: " + filled;
    }
}